#pragma once

#include "common.h"

#include <vector>
using namespace std;

template	< TYPENAME T >
class CMyStack
{
public:
	void	push	(T obj)				{ m_set.push_back(obj); }
	T		pop		(void)				{ IF_OK(size()) { T obj = m_set.back(); m_set.pop_back(); return obj; } return T(); }
	int		size	(void)				{ return m_set.size(); }
	void	clear	(void)				{ m_set.clear(); }
protected:
	typedef	vector<T>	STACK_SET;
	STACK_SET			m_set;
};

